﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;
using CommunitySystem.SystemService;
using EHR.Common;

namespace CommunitySystem
{
    public partial class UpdatePasswordWindow : ChildWindow
    {
        SystemService.SystemServiceClient Client = new SystemService.SystemServiceClient();
        SystemService.UserInfo UserInfoModel = new SystemService.UserInfo();
        public UpdatePasswordWindow()
        {
            InitializeComponent();
        }


        /// <summary>
        /// 修改密码
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void OKButton_Click(object sender, RoutedEventArgs e)
        {

            Client.UpdatePassCompleted += new EventHandler<UpdatePassCompletedEventArgs>(Client_UpdatePassCompleted);
            Client.UpdatePassAsync(Pa1.Text, Session.LoginUser.UserID);

            this.DialogResult = true;
        }

        void Client_UpdatePassCompleted(object sender, UpdatePassCompletedEventArgs e)
        {
            //throw new NotImplementedException();
        }

        private void CancelButton_Click(object sender, RoutedEventArgs e)
        {
            this.DialogResult = false;
        }
    }
}

